import request from '@/utils/request'

//添加关联视频
export function addVideo(data) {
  return request({
    url: "/cms/display/videos",
    method: "post",
    data: data
  })
}

//取消关联视频
export function deleteVideo(data) {
  return request({
    url: "/cms/display/videos",
    method: "delete",
    data: data
  })
}

//关联视频
export function listVideo(id) {
  return request({
    url: "/cms/display/" + id + "/videos",
    method: "get"
  })
}

//关联logo
export function editLogo(data) {
  return request({
    url: "/cms/display/logos",
    method: "put",
    data: data
  })
}

//关联logo
export function deleteLogo(id, data) {
  return request({
    url: "/cms/display/" + id + "/logos",
    method: "delete",
    data: data
  })
}

//关联logo
export function addLogo(data) {
  return request({
    url: "/cms/display/logos",
    method: "post",
    data: data
  })
}

//logo
export function listLogos(id) {
  return request({
    url: "/cms/display/" + id + "/logos",
    method: "get"
  })
}

//关联logo
export function listLogo(id) {
  return request({
    url: "/cms/display/" + id + "/logo",
    method: "get"
  })
}

// 查询展示屏管理列表
export function listDisplay(query) {
  return request({
    url: '/cms/display/list',
    method: 'get',
    params: query
  })
}

// 查询展示屏管理详细
export function getDisplay(id) {
  return request({
    url: '/cms/display/' + id,
    method: 'get'
  })
}

// 新增展示屏管理
export function addDisplay(data) {
  return request({
    url: '/cms/display',
    method: 'post',
    data: data
  })
}

// 修改展示屏管理
export function updateDisplay(data) {
  return request({
    url: '/cms/display',
    method: 'put',
    data: data
  })
}

// 删除展示屏管理
export function delDisplay(id) {
  return request({
    url: '/cms/display/' + id,
    method: 'delete'
  })
}

// 导出展示屏管理
export function exportDisplay(query) {
  return request({
    url: '/cms/display/export',
    method: 'get',
    params: query
  })
}